package cn.muqingfeng.api.to;

import android.os.Parcel;

import com.google.gson.annotations.SerializedName;

public class LoginResponseTO extends BaseResponseTO {
	@SerializedName("data")
	private UserTO user;

	public LoginResponseTO() {
		super();
	}

	public LoginResponseTO(Parcel source) {
		super(source);
		this.user = source.readParcelable(UserTO.class.getClassLoader());
	}

	@Override
	public void writeToParcel(Parcel dest, int flags) {
		super.writeToParcel(dest, flags);
		dest.writeParcelable(user, flags);
	}

	public static final Creator<LoginResponseTO> CREATOR = new Creator<LoginResponseTO>() {

		@Override
		public LoginResponseTO[] newArray(int size) {
			return new LoginResponseTO[size];
		}

		@Override
		public LoginResponseTO createFromParcel(Parcel source) {
			return new LoginResponseTO(source);
		}
	};

	public UserTO getUser() {
		return user;
	}

	public void setUser(UserTO user) {
		this.user = user;
	}

}
